package com.example.test.thread;

/**
 * @Description: java类作用描述
 * @Author: 明天
 * @CreateDate: 2019/1/17$ 14:54$
 * @UpdateDate: 2019/1/17$ 14:54$
 * @UpdateRemark: 修改内容
 * @Version: 1.0
 * 参考地址：https://www.toutiao.com/a6646938191863480835/?tt_from=weixin&utm_campaign=client_share&wxshare_count=1&timestamp=1547701010&app=news_article&utm_source=weixin&iid=57315554767&utm_medium=toutiao_android&group_id=6646938191863480835
 */
public class TempThread implements Runnable {
    @Override
    public void run() {
        //打印正在执行的缓存线程信息
        System.out.println(Thread.currentThread().getName()+"正在被执行。");
        try {
            //sleep一秒保证3个任务在分别三个线程上执行
            Thread.sleep(1000);
        } catch (InterruptedException e) {
            e.printStackTrace();
        }
    }
}
